
IF(NOT TCG_ARCH)
message(FATAL_ERROR "TCG_ARCH is not defined, use cmake -D to define it, maybe i386/arm/hppa/ia64/mips/ppc/ppc64/s390/sparc/tci")
ENDIF()
include_directories(tcg/${TCG_ARCH})
set(QEMU_SRCS ${QEMU_SRCS} cpu-exec.c cputlb.c disas.c exec.c memory.c qemu-log.c tcg-runtime.c translate-all.c)
set(QEMU_SRCS ${QEMU_SRCS} disas/i386.c disas/tci.c)
set(QEMU_SRCS ${QEMU_SRCS} fpu/softfloat.c)
set(QEMU_SRCS ${QEMU_SRCS} qapi/qapi-visit-core.c qapi/qmp-input-visitor.c qapi/qmp-output-visitor.c qapi/string-input-visitor.c qapi/string-output-visitor.c)
set(QEMU_SRCS ${QEMU_SRCS} qobject/qbool.c qobject/qdict.c qobject/qfloat.c qobject/qint.c qobject/qlist.c qobject/qstring.c)
set(QEMU_SRCS ${QEMU_SRCS} qom/container.c qom/cpu.c qom/object.c qom/qom-qobject.c)
set(QEMU_SRCS ${QEMU_SRCS} target-i386/cc_helper.c target-i386/cpu.c target-i386/excp_helper.c target-i386/fpu_helper.c target-i386/helper.c target-i386/int_helper.c target-i386/ioport-user.c target-i386/mem_helper.c target-i386/misc_helper.c target-i386/seg_helper.c target-i386/smm_helper.c target-i386/svm_helper.c target-i386/translate.c)
set(QEMU_SRCS ${QEMU_SRCS} tcg/tcg.c tcg/optimize.c)
set(QEMU_SRCS ${QEMU_SRCS} util/cutils.c util/error.c util/module.c util/host-utils.c)
add_library(qemu STATIC ${QEMU_SRCS})